package com.xt.purchasingsystem.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.xt.purchasingsystem.dto.ExecutePurchaseDto;
import com.xt.purchasingsystem.dto.OutboundProcurementDto;
import com.xt.purchasingsystem.model.OutboundProcurement;
import com.xt.purchasingsystem.utils.Result;

/**
 * <p>
 *  出库采购业务类
 * </p>
 *
 * @author yhp
 * @since 2020-06-06
 */
public interface OutboundProcurementService extends IService<OutboundProcurement> {
    /**
     * 添加出库采购及其出库采购明细的业务
     * @param outboundProcurementDto
     * @return
     */
    Result saveOutboundProcurement(OutboundProcurementDto outboundProcurementDto);

    /**
     * 分页查询所有未生成采购计划单的出库采购及其明细的业务
     * @param currNo
     * @param pageSize
     * @return
     */
    Result getAllNoPurchaseByPage(Integer currNo, Integer pageSize);

    /**
     * 修改出库采购拟采购总数和出库采购明细拟采购数量的业务
     * @param outboundProcurementDto
     * @return
     */
    Result updateOutboundProcurementAndDetailsPurchaseAmount(OutboundProcurementDto outboundProcurementDto);

    Result executePurchase(ExecutePurchaseDto executePurchaseDto);
}
